C = g++ -Wno-deprecated
CFLAGS = -c -Wall -g
DFLAGS = -DDEBUG=1
TARGET = main.seq
TARGETDEBUG = mainD.seq
MAKETESTS = ../../utils/maketests

seq: $(TARGET)
seqdebug: $(TARGETDEBUG)


########################### SECUENCIAL ###############################

$(TARGET): Cutting2D.o
	  $(C) Cutting2D.o -o $@

Cutting2D.o: Cutting2D.c Cutting2D.h dynprog.c upperbound.c
	  $(C) $(CFLAGS) Cutting2D.c -o $@


$(TARGETDEBUG): Cutting2DD.o
	  $(C) Cutting2DD.o -o $@

Cutting2DD.o: Cutting2D.c Cutting2D.h
	  $(C) $(CFLAGS) $(DFLAGS) Cutting2D.c -o $@

################################################################################

plot: seq
	R
test: seq
	./maketest 
createtest: seq
	perl ./$(MAKETESTS) -c 
clean:
	-rm -f *.o *.seq *.omp *.stackdump *.tmp *~ out output.*
